package com.zyguo.sdk.websocket;

import java.io.Serializable;

import org.msgpack.annotation.Message;

@Message
public class RequestMsg<T extends Object> implements Serializable {
	private static final long serialVersionUID = -6543794901788419802L;
	private RequestHeader header; //消息头
	private T body; //消息体

	public RequestMsg(RequestHeader header, T body) {
		this.header = header;
		this.body = body;
	}
	
	public RequestHeader getHeader() {
		return header;
	}

	public void setHeader(RequestHeader header) {
		this.header = header;
	}

	public T getBody() {
		return body;
	}

	public void setBody(T body) {
		this.body = body;
	}

	@Override
	public String toString() {
		return this.header + ":" + this.body;
	}
}
